package cate.game.train.equip.msg;

import cate.common.annotation.OperationSetter;
import cate.common.table.d.GDOperation;
import cate.game.GameBody;
import cate.game.client.ClientContext;
import cate.game.client.msg.ClientMsg;
import cate.game.client.msg.MsgConfig;
import cate.game.client.msg.MsgInput;
import cate.game.client.msg.id.MsgIdBTrain;
import easy.java.dev.note.NoteField;

import java.util.Set;

@ClientMsg(title = "英雄穿装备の 请求")
@OperationSetter(GDOperation.EQUIP_ON)
public class HeroEquipOnReq implements MsgInput {
    @NoteField(value = "英雄ID", detail = "要给哪一个英雄穿装备")
    public String heroUid;

    @NoteField(value = "装备唯一们", detail = "要穿的那些装备们的唯一ID")
    public Set<String> equipUidList;

    @Override
    public void execute(GameBody game, ClientContext cc) {
        game.train.equip.onEquip(cc.getRole(), heroUid, equipUidList);
    }

    @Override
    public MsgConfig conf() {
        return MsgIdBTrain.HERO_EQUIP_ON_REQ;
    }
}
